// 版权归 Epic Games, Inc. 所有。保留所有权利。

#pragma once

#include "GameFeatureAction.h"

#include "ApplyFrontendPerfSettingsAction.generated.h"

class UObject;
struct FGameFeatureActivatingContext;
struct FGameFeatureDeactivatingContext;

//////////////////////////////////////////////////////////////////////
// UApplyFrontendPerfSettingsAction

/**
 * 负责通知用户设置应用前端/菜单特定性能设置的 GameFeatureAction
 */
UCLASS(MinimalAPI, meta = (DisplayName = "使用前端性能设置"))
class UApplyFrontendPerfSettingsAction final : public UGameFeatureAction
{
	GENERATED_BODY()

public:
	//~UGameFeatureAction 接口
	/**
	 * 当游戏功能激活时调用
	 * @param Context 游戏功能激活上下文
	 */
	virtual void OnGameFeatureActivating(FGameFeatureActivatingContext& Context) override;
	/**
	 * 当游戏功能取消激活时调用
	 * @param Context 游戏功能取消激活上下文
	 */
	virtual void OnGameFeatureDeactivating(FGameFeatureDeactivatingContext& Context) override;
	//~UGameFeatureAction 接口结束

private:
	static int32 ApplicationCounter; // 静态应用计数器，用于跟踪激活状态的实例数量
};